package edu.uwm.cs552;

import java.awt.Color;
import java.awt.Graphics;

public class PlayerBoardPanel extends HexBoardPanel {
	/**
	 * Keep Eclipse happy
	 */
	private static final long serialVersionUID = 1L;
	
	private final RailGame game;
	private final Player player;
	
	public PlayerBoardPanel(RailGame g, Player p, HexBoard board) {
		super(board);
		game = g;
		player = p;
		game.addObserver(this);
	}
	
	@Override
	public void paint(Graphics g) {
		g.setColor(Color.BLACK);
		super.paint(g);
		game.draw(g,getScale(),player);
	}
}
